import static org.junit.Assert.*;

import org.junit.Before;
import org.junit.Test;


public class tCircle {
	Circle c;
    Circle c2;
	
	@Before
    public void setUp() {
		c = new Circle(10,10,50);
		c2 = new Circle(10,10,77);
    }

	@Test
	public final void testSetWeightCenter() {
		
	    c.setWeightCenter();
		assertEquals("Weight center X ", 10, c.weightCenterX);
		assertEquals("Weight center Y ", 10, c.weightCenterY);
	}

	@Test
	public final void testPerimeter() {
				
		assertEquals("Perimetr of circle 1 should be 314", 314, c.perimeter());
		assertEquals("Perimetr of circle 2 should be 314", 483.57, c2.perimeter());

	}

	@Test
	public final void testArea() {
		assertEquals("Area of circle ", 7850, c.area());
		assertEquals("Area of cicle 2", 18617.06, c2.area());
	}

	
	@Test
	public final void testGetRadius() {
		assertEquals("Radius of circle ", 50, c.getRadius());
		assertEquals("Radius of cicle 2", 77, c2.getRadius());
	}

	
}
